import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomePage.vue'


Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Homepage',
    component: () => import('../views/HomePage.vue')
  },
  {
    path:"/sign-in",
    name:"SignIn",
    component: () => import('../views/SignIn.vue'),
    redirect:"/sign-in/select",
    children:[
      {path:"select", name:"Select", component: () => import('../views/Select.vue')},
      {path:"publish", name:"Publish", component: () => import('../views/Publish.vue')},
      {path:"unpublished", name:"Unpublished", component: () => import('../views/Unpublished.vue')},
      {path:"published", name:"Published", component: () => import('../views/Published.vue')},
      { path:"details",
        name:"Details",
        component: () => import('../views/Details.vue'),
        // redirect:"/sign-in/details/signed",
        children:[
          {path:"signed", name:"Signed", component: () => import('../views/Signed.vue')},
          {path:"unsigned", name:"Unsigned", component: () => import('../views/Unsigned.vue')},
        ]
      },
    ]
  },
  {
    path:"/signIn-staff",
    name:"SignInStaff",
    component: () => import('../views/SignInStaff.vue'),
    redirect:"/signIn-staff/unfinished",
    children:[
      {path:"unfinished", name:"Unfinished", component: () => import('../views/Unfinished.vue')},
      {path:"finished", name:"Finished", component: () => import('../views/Finished.vue')},
    ]
  },
  {
    path:"/vote",
    name:"Vote",
    component: () => import('../views/Vote.vue')
  },
  {
    path:"/random-call",
    name:"RandomCall",
    component: () => import('../views/RandomCall.vue')
  },
  {
    path:"/WW_verify_8XhDeLhcXlJaXfcv.txt",
    name:"check",
    component: () => import('../views/check.vue')
  },

]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
